# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python2-pysmbc
_pkgname=pysmbc
pkgver=1.0.16
pkgrel=1
pkgdesc='Python bindings for libsmbclient.'
arch=('x86_64' 'aarch64')
url='https://pypi.org/project/pysmbc/'
license=('GPL')
depends=('python2' 'smbclient')
makedepends=('python2-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.bz2")
sha512sums=('4df1733fb6ad1499dc7b5385edb8acdeea753e7d749a5e01248eb9b7284418f498346ed475774003dcf6f7b30083935cfbe3cc5ab9dcc4da15c6d924f6e68197')

build() {
  cd "$_pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$_pkgname-$pkgver"

  python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=1 \
    --skip-build
}

